home *** CD-ROM | disk | FTP | other *** search
/ Revista do CD-ROM 124 / cd-rom 124.iso / edu / tuxmath / tuxmathscrabble / asymptopia / Animator.pyc (.txt) < prev    next >
Encoding:
Python Compiled Bytecode  |  2003-11-16  |  2.9 KB  |  57 lines

  1. # Source Generated with Decompyle++
  2. # File: in.pyc (Python 2.2)
  3.  
  4. '''
  5. /***************************************************************************
  6.  
  7. \tAuthor \t\t\t:Charles B. Cosse 
  8. \t
  9. \tEmail\t\t\t:ccosse@asymptopia.com
  10. \t\t\t\t\t
  11. \tCopyright\t\t:(C) 2002,2003 Asymptopia Software.
  12. \t
  13.  ***************************************************************************/
  14. /***************************************************************************
  15.                           Animator.py
  16.  
  17.  
  18.  ***************************************************************************/
  19.  
  20. /***************************************************************************
  21.  *                                                                         *
  22.  *   This program is free software; you can redistribute it and/or modify  *
  23.  *   it under the terms of the GNU General Public License as published by  *
  24.  *   the Free Software Foundation; either version 2 of the License, or     *
  25.  *   (at your option) any later version. (Please note that if you use this *
  26.  *   code you must give credit by including the Author and Copyright       *
  27.  *   info at the top of this file).                                        *
  28.  ***************************************************************************/
  29.  
  30. '''
  31. import os
  32. import pygame
  33. import sys
  34. from pygame.locals import *
  35. from random import random
  36.  
  37. class Animator:
  38.     
  39.     def __init__(self):
  40.         self.characters = { }
  41.         self.maneuvers = { }
  42.  
  43.     
  44.     def add_char(self, name, char):
  45.         self.characters[name] = char
  46.  
  47.     
  48.     def start_maneuver(self, who, which):
  49.         maneuvers = self.maneuvers
  50.         self.characters[who].begin_maneuver(maneuvers[which])
  51.  
  52.     
  53.     def define_maneuver(self, name, maneuver):
  54.         self.maneuvers[name] = maneuver
  55.  
  56.  
  57.